FROM registry.gitee-ai.local/base/iluvatar-corex:3.2.0-bi100

# 设置工作目录
WORKDIR /app

# 将当前目录的内容复制到容器中的 /app 目录下
COPY .. /app

# 安装所需的包
RUN pip install --no-cache-dir -r requirements.txt

# qwen2-vl 安装使用
#WORKDIR /data
#RUN ls -l
#RUN git clone https://github.com/huggingface/transformers
#WORKDIR /data/transformers
#RUN python setup.py install
#WORKDIR /app
#RUN pip install git+https://github.com/huggingface/transformers accelerate
#COPY /tmp /data/tmp

# 设置环境变量
ENV FLASK_APP=main.py
ENV FLASK_RUN_HOST=0.0.0.0
ENV FLASK_RUN_PORT=7860

# 暴露端口
EXPOSE 7860

# 运行 flask 命令
CMD ["flask", "run", "--host", "0.0.0.0", "--port", "7860"]